﻿body.overlay:after {
    content: '';
    display: block;
    position: fixed;
    top: @navbar-height;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 100%;
    z-index: @zindex-dropdown - 1;
    background: rgba(0,0,0,0.7);
}

.mega-menu {
    .dropdown {
        position: static !important;
    }

    .mega-dropdown-menu {
        padding: 0;
        width: 100%;
        border-width: 0;
        .box-shadow(none);

        ul {
            margin-top: 0;
            margin-left: 16px;
        }
    }

    .mega-menu-headline {
        padding: 10px 15px;
        margin-left: 16px;
        border-left: solid 1px @gray-lighter;

        a {
            font-weight: bold;
            font-size: @mega-menu-level1-font-size;
            color: @headings-color;

            &:hover {
                color: @link-color;
                text-decoration: none;
            }
        }

        .description {
            display: none;
        }
    }

    > li > a {
        font-size: @mega-menu-level1-font-size;
    }

    .nav.level-2 {
        border-left: solid 1px @gray-lighter;

        > li > a {
            font-size: @mega-menu-level2-font-size;
            padding-bottom: 5px;
        }
    }

    .nav.level-3 {
        margin-bottom: 10px;

        a {
            font-size:  @mega-menu-level3-font-size;
            font-weight: normal;
            padding-top: 0;
        }
    }
}

&.navbar-nav > li > .dropdown-menu {
    border-color: @gray-lighter;
}



/*** DESKTOP ***/
@media (min-width: @grid-float-breakpoint) {
    .mega-menu {

        .mega-dropdown-menu {
            padding-left: 2.5%;
            padding-bottom: 45px;
        }

        .mega-menu-headline {
            padding: 10px 0 20px 0;
            width: 98%;
            border-left: 0;
            border-bottom: solid 1px darken(@gray-lighter, 10%);
            margin-left: -0.25em;
            margin-right: 0;

            a {
                font-size: @font-size-h1;
                font-weight: bold;
                color: @headings-color;
            }

            .description {
                margin-bottom: 10px;
                display: block;
            }
        }

        .nav.level-2 {
            margin-left: 0;
            border-left: 0;

            > li {
                display: inline-block;
                margin: 0 2% 0 0;
                /* IE7 hack to mimic inline-block on block elements */
                *display: inline;
                *zoom: 1;
                vertical-align: top;
                width: 23%;
                margin-left: -0.25em;

                > a {
                    padding: 20px 0;

                    &:hover {
                        background: transparent;
                    }
                }

                > a {
                    border-bottom: solid 1px @gray-lighter;
                }
            }
        }

        .nav.level-3 {
            margin-left: 0;

            > li > a {
                padding-left: 0;
                padding-top: 10px;
                padding-bottom: 0;
            }

            ul {
                display: none;
            }
        }
    }
}
@media (min-width: (@screen-lg + 100)) {
    .mega-menu {
        .mega-dropdown-menu {
            padding-left: 221px;
            padding-right: 221px;
        }
    }
}
